package facade;

import interfaces.IFHotelController;

import java.rmi.RemoteException;
import java.rmi.server.UnicastRemoteObject;
import java.util.List;

import model.Hotel;
import controller.HotelController;

@SuppressWarnings("serial")
public class FachadaServicos extends UnicastRemoteObject implements IFHotelController {
	
	private HotelController hotelController;

	public FachadaServicos() throws RemoteException {
		hotelController = new HotelController();
	}

	@Override
	public Hotel criarHotel(String nome, String gerente, Integer numeroDeQuartos)
			throws RemoteException {
		Hotel h = hotelController.criarHotel(nome, gerente, numeroDeQuartos);
		return h;
	}

	@Override
	public List<Hotel> getHoteis() throws RemoteException {
		return hotelController.getHoteis();
	}
	
	

}
